home *** CD-ROM | disk | FTP | other *** search
/ The Atari Compendium / The Atari Compendium (Toad Computers) (1994).iso / files / prgtools / mint / mntdoc01.zoo / mintdoc / cat3 / fclose.3 < prev    next >
Encoding:
Text File  |  1993-03-03  |  1.4 KB  |  67 lines

  1.  
  2.  
  3.  
  4. FCLOSE(3)           MINTLIB LIBRARY FUNCTIONS           FCLOSE(3)
  5.  
  6.  
  7. N✓NA✓AM✓ME✓E
  8.        fclose, fflush - close or flush a stream
  9.  
  10. S✓SY✓YN✓NO✓OP✓PS✓SI✓IS✓S
  11.        #include <stdio.h>
  12.  
  13.        int fclose(FILE *stream);
  14.  
  15.        int fflush(FILE *stream);
  16.  
  17. D✓DE✓ES✓SC✓CR✓RI✓IP✓PT✓TI✓IO✓ON✓N
  18.        fclose  writes out any buffered data for the named stream,
  19.        and closes the named  stream.  Buffers  allocated  by  the
  20.        standard input/output system are freed.
  21.  
  22.        fclose  is performed automatically for all open files upon
  23.        calling exit.
  24.  
  25.        fflush writes any unwritten data for an output  stream  or
  26.        an  update  stream  in which the most recent operation was
  27.        not input to be delivered to the host environment  to  the
  28.        file;  otherwise  it  is ignored. The named stream remains
  29.        open.
  30.  
  31. R✓RE✓ET✓TU✓UR✓RN✓N V✓VA✓AL✓LU✓UE✓ES✓S
  32.        fclose returns:
  33.  
  34.          0 on success.  EOF if any error (such as trying to write
  35.        to a file that
  36.            has not been opened for writing) was detected.
  37.  
  38.        fflush returns:
  39.  
  40.          0  on  success  or  if  the file wasn't open.  EOF if an
  41.        error was detected while writing the data.
  42.  
  43.  
  44. S✓SE✓EE✓E A✓AL✓LS✓SO✓O
  45.        c✓cl✓lo✓os✓se✓e(✓(3✓3)✓),✓, e✓ex✓xi✓it✓t(✓(3✓3)✓),✓, f✓fo✓op✓pe✓en✓n(✓(3✓3)✓),✓, s✓se✓et✓tb✓bu✓uf✓f(✓(3✓3)✓)
  46.  
  47.  
  48.  
  49.  
  50.  
  51.  
  52.  
  53.  
  54.  
  55.  
  56.  
  57.  
  58.  
  59.  
  60.  
  61.  
  62.  
  63.  
  64. MiNT docs 0.1              3 March 1993                         1
  65.  
  66.  
  67.